Skip to content

FOUR-31702 Self-service task with a timer event to complete the request still appears as active - #9080

Open
devmiguelangel wants to merge 7 commits into
developfrom
FOUR-31702
Open

devmiguelangel wants to merge 7 commits into
developfrom
FOUR-31702

Conversation

@devmiguelangel

@devmiguelangel devmiguelangel commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Issue & Reproduction Steps

An interrupting boundary timer closes an unclaimed self-service task. The task retains its historical is_self_service = 1 flag, but it must disappear from active Self Service results and must not be labeled Self Service in historical charts.

Solution

  • Do not clear is_self_service, claim/reassign the task, or populate completed_at when an activity closes.
  • Keep the active-list contract query-side: available self-service tasks require status = ACTIVE, remain unassigned, and preserve user/group/manager eligibility. Reuse this predicate for user-ID and assignment-scope listings; the no-auth semantic Self Service query also requires ACTIVE.
  • Preserve raw is_self_service = 1 PMQL semantics for historical/diagnostic searches. The semantic status = "Self Service" filter is the active-availability filter.
  • Add regression coverage for interrupting/non-interrupting timers, closure while the request continues, retained assignment state, active semantic listing versus raw flag query, and assigned historical tasks.

Verification

  • Manual tests were run by the author; all are green.
  • PHP syntax and diff checks pass. No automated test suite was run as part of this change.

Related Tickets & Packages

FOUR-31702
Saved Search PR #701

Code Review Checklist

  • I have pulled this code locally and manually tested it on my instance, along with the associated package.
  • This code includes regression tests for the changed behavior.
  • This code adheres to ProcessMaker Coding Guidelines.
  • This solution does not alter expected process behavior or introduce breaking changes.
  • Enterprise package compatibility and PRD requirements have been verified.

ci:package-savedsearch:FOUR-31702
ci:deploy

@devmiguelangel devmiguelangel self-assigned this Sep 28, 2026
@cursor

cursor Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

PR Summary

Medium Risk
Changes task list/PMQL semantics for self-service and user filters, which affects saved searches and dashboards; behavior is covered by new tests but touches widely used query paths.

Overview
Treats Self Service as an active, unclaimed availability filter: closed self-service tasks (e.g. after an interrupting boundary timer) stay is_self_service = 1 for history but drop out of status = "Self Service" and user-assignment listings.

Query changes centralize eligibility on User::availableSelfServiceTasksQuery() (ACTIVE, user_id null, group/user rules) for PMQL when a user is present, scopeWhereUserAssigned, and task index user_id filtering. Unauthenticated Self Service filters now also require ACTIVE and unassigned, not only is_self_service = 1. Raw is_self_service = 1 PMQL is unchanged for diagnostics.

Tests add timer boundary scenarios for self-service tasks, API/scope coverage for excluding closed self-service while keeping assigned closed tasks, filter SQL assertions, and a BPMN fixture.

Reviewed by Cursor Bugbot for commit 90fd8cf. Bugbot is set up for automated code reviews on this repo. Configure here.

@vladyrichter

This comment was marked as outdated.

@nolanpro

Copy link
Copy Markdown
Contributor

QA server K8S was successfully deployed https://tenant-1.ci-37fb4aefb9.engk8s.processmaker.net

@decisions-sonarqube

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants